package com.wjf.resourceservice.feign;

import com.wjf.common.entity.Result;
import com.wjf.common.config.FeignConfiguration;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestHeader;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(name = "USER-SERVICE",configuration = FeignConfiguration.class)
public interface UserClient {
    
    /**
     * 获取当前用户信息
     */
    @GetMapping("/users/current")
    Result<?> getCurrentUser();
    
    /**
     * 检查用户VIP状态
     */
    @GetMapping("/users/check-vip")
    Result<Boolean> checkUserVip();
    
    /**
     * 检查用户是否有指定权限
     */
    @GetMapping("/users/check-permission")
    Result<Boolean> checkPermission(@RequestParam("code") String permissionCode);
} 